<template>
  <view class="public-opinion-history-root" :style="fullStyle">
    <top-back-image-container style="width: 100%;height: max-content"
                              :image-path="`${baseFilePath}/home/historicalPublicOpinion.png`"></top-back-image-container>
    <view class="content">
      <historical-message :representativeFieldName="representativeFieldName" :show-query-input="true" :dialogue-query-url="MASS_GET_LIAISON_MESSAGE_SESSION" :dialogue-submit-url="MASS_MESSAGING"
                          :query-url="QUERY_MASS_OPINION_HISTORY" style="width: 100%"></historical-message>
    </view>
  </view>
</template>

<script>
import TopBackImageContainer from "@/compontent/topBackImageContainer/index.vue";
import historicalMessage from "@/compontent/historicalMessage/index.vue";
import {MASS_GET_LIAISON_MESSAGE_SESSION, MASS_MESSAGING, QUERY_MASS_OPINION_HISTORY} from "@/api/representative";
import {baseFilePath} from "@/until/publicConfig";
import {baseMixins} from "@/mixins/baseMixins";

export default {
  mixins:[baseMixins],
  components: {historicalMessage, TopBackImageContainer},
  data() {
    return {
      baseFilePath,
      QUERY_MASS_OPINION_HISTORY,
      MASS_MESSAGING,
      MASS_GET_LIAISON_MESSAGE_SESSION,
      representativeFieldName:'targetRepresentativeId_dictText'
    }
  }
}
</script>

<style lang="scss">
.public-opinion-history-root {
  width: 750rpx;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  overflow-y: auto;
  background: #f8f8f8;

  .content {
    width: 100%;
    padding: 20rpx;
    margin-top: 30rpx;
  }
}
</style>
